package com.zhejiangzhengyuan.municipal_common.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.sql.Timestamp;

/**
 * <p>
 * 巡检记录表，用于记录目前巡检工作产生数据
 * </p>
 *
 * @author linju
 * @since 2019-11-22
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value="InspectionRecord对象", description="巡检记录表，用于记录目前巡检工作产生数据")
public class InspectionRecord extends Model<InspectionRecord> {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "自增主键")
    @TableId(value = "id",type = IdType.AUTO)
    private Long id;
    @ApiModelProperty(value = "巡检人员，关联用户表")
    private Long inspectionUserInfoId;
    @ApiModelProperty(value = "记录创建时间")
    private Timestamp createTime;
    @ApiModelProperty(value = "记录更新时间")
    private Timestamp updateTime;
    @ApiModelProperty(value = "任务外键")
    private Long inspectionTasksId;
    @ApiModelProperty(value = "巡检目标")
    private String targetId;
    @ApiModelProperty(value = "巡检结果描述,巡检中发现问题通过巡检事件上报")
    private String result;

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}
